import unittest
from time import sleep
from selenium import webdriver
from selenium.webdriver.firefox.options import Options
import Login


class mytest02(unittest.TestCase):
    def setUp(self):
        self.driver =Login.login()
    def test_zhengxiang_02(self):
        self.driver.find_element('link text', '文档管理').click()
        sleep(1)
        self.driver.find_element('link text', '借阅文档').click()
        sleep(1)
        ele1 = self.driver.find_element('css selector', '#iframe_main')  # 进入新建文件层
        self.driver.switch_to.frame(ele1)
        self.driver.find_element('link text', '单位借阅').click()
        sleep(1)
    def tearDown(self) -> None:
        self.driver.close()
if __name__ == '__main__':
        unittest.main()